varying vec3 vPosition;
varying vec3 vTexcoord0;
varying vec3 vNormal;
uniform vec3 uLightPosition;
uniform vec4 uDiffuseColor;
uniform vec4 uLightColor;
uniform float uShininess;

void main()
{
    vec3 lightDir=normalize(uLightPosition-vPosition);
	float diff=max(0.0,dot(vNormal,lightDir));
	
	vec3 eyeDir=normalize(-vPosition);
	vec3 reLight=normalize(reflect(lightDir,vNormal));
	float spec=(pow(max(0.0,dot(reLight,-eyeDir)),255.0));
	
	gl_FragColor=vec4(1,0,0,1)*diff+vec4(1.0,1.0,1.0,1.0)*spec;
}